import java.util.Scanner;

/**
 * Created by L.jp
 * Description:
 * User: 86189
 * Date: 2021-10-05
 * Time: 21:57
 */
public class Factorial {
    public static void main(String[] args) {
        Scanner scan=new Scanner(System.in);
        int n=scan.nextInt();
        int ret=1;
        for (int i = 1; i <=n; i++) {
            ret*=i;

        }
        System.out.println(ret);
    }
}

